#include "UsageEnvironment.hh"

#ifndef _AUDIO_INPUT_DEVICE_HH
#include "AudioInputDevice.hh"
#endif

class IPCameraAACAudioSource : public FramedSource
{
public:
	static IPCameraAACAudioSource* createNew(UsageEnvironment& env, int sampling_frequency, int channel_configuration);

	int samplingFrequency() const { return fSamplingFrequency; }
	int numChannels() const { return fNumChannels; }
	char const* configStr() const { return fConfigStr; }
	// returns the 'AudioSpecificConfig' for this stream (in ASCII form)

private:
	IPCameraAACAudioSource(UsageEnvironment& env, int samplingFrequency, int channelConfiguration);
	// called only by createNew()

	virtual ~IPCameraAACAudioSource();

private:
	// redefined virtual functions:
	virtual void doGetNextFrame();

private:
	unsigned fSamplingFrequency;
	unsigned fNumChannels;
	unsigned fuSecsPerFrame;
	char fConfigStr[5];

public:
	int		int_stream_id;
	void*	ptr_frame_buffer;
};
